package com.sport.facilities.booking.system.model;

import java.io.Serializable;

public class MakeBookFormModel implements Serializable {
	private static final long serialVersionUID = 1L;
	/*
	 * Data for booking check
	 * */
	String activity = "";
	String centre = "";
	String st_day = "";
	String ed_day = "";
	String st_time = "";
	String ed_time = "";
	
	/*
	 * useful info from page
	 * */
	String name = "";
	String note = "";
	String credit = "";
	
	
	/*
	 * Data need to send back to web
	 * */
	String submitName = ""; // form submit Name
	String submitValue = ""; // form submit Name
	String kaptchaName = ""; // {kaptchafield} kaptcha submit Name
	String kaptchaValue = ""; // kaptcha submit value MaxLen : 4

	String activitySubmitName = "lst_activity";
	String centreSubmitName = "lst_centre";
	String st_daySubmitName = "lst_st_day";
	String ed_daySubmitName = "lst_ed_day";
	String st_timeSubmitName = "lst_st_time";
	String ed_timeSubmitName = "lst_ed_time";
	
	/*
	 * These values are only for booking confirmation.
	 * */
	String activityCodeName = "lactivity";
	String activityCodeValue = "";
	
	String[] lst_activity = { "" };
	String[] lst_centre = { "" };
	String[] lst_st_day = { "" };
	String[] lst_ed_day = { "" };
	String[] lst_st_time = { "" };
	String[] lst_ed_time = { "" };

	public String getActivity() {
		return activity;
	}

	public void setActivity(String activity) {
		this.activity = activity;
	}

	public String getCentre() {
		return centre;
	}

	public void setCentre(String centre) {
		this.centre = centre;
	}

	public String getSt_day() {
		return st_day;
	}

	public void setSt_day(String st_day) {
		this.st_day = st_day;
	}

	public String getEd_day() {
		return ed_day;
	}

	public void setEd_day(String ed_day) {
		this.ed_day = ed_day;
	}

	public String getSt_time() {
		return st_time;
	}

	public void setSt_time(String st_time) {
		this.st_time = st_time;
	}

	public String getEd_time() {
		return ed_time;
	}

	public void setEd_time(String ed_time) {
		this.ed_time = ed_time;
	}

	public String getCredit() {
		return credit;
	}

	public void setCredit(String credit) {
		this.credit = credit;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getNote() {
		return note;
	}

	public void setNote(String note) {
		this.note = note;
	}

	public String getSubmitName() {
		return submitName;
	}

	public void setSubmitName(String value) {
		this.submitName = value;
	}

	public String getSubmitValue() {
		return submitValue;
	}

	public void setSubmitValue(String submitVale) {
		this.submitValue = submitVale;
	}

	public String getKaptchaName() {
		return kaptchaName;
	}

	public void setKaptchaName(String kaptchaName) {
		this.kaptchaName = kaptchaName;
	}

	public String getKaptchaValue() {
		return kaptchaValue;
	}

	public void setKaptchaValue(String kaptchafield) {
		if (kaptchafield.length() > 4) {
			this.kaptchaValue = kaptchafield.substring(0, 3);
		} else {
			this.kaptchaValue = kaptchafield;
		}
	}

	public String[] getLst_activity() {
		return lst_activity;
	}

	public void setLst_activity(String[] lst_activity) {
		this.lst_activity = lst_activity;
	}

	public String[] getLst_centre() {
		return lst_centre;
	}

	public void setLst_centre(String[] lst_centre) {
		this.lst_centre = lst_centre;
	}

	public String[] getLst_st_day() {
		return lst_st_day;
	}

	public void setLst_st_day(String[] lst_st_day) {
		this.lst_st_day = lst_st_day;
	}

	public String[] getLst_ed_day() {
		return lst_ed_day;
	}

	public void setLst_ed_day(String[] lst_ed_day) {
		this.lst_ed_day = lst_ed_day;
	}

	public String[] getLst_st_time() {
		return lst_st_time;
	}

	public void setLst_st_time(String[] lst_st_time) {
		this.lst_st_time = lst_st_time;
	}

	public String[] getLst_ed_time() {
		return lst_ed_time;
	}

	public void setLst_ed_time(String[] lst_ed_time) {
		this.lst_ed_time = lst_ed_time;
	}

	public String getActivitySubmitName() {
		return activitySubmitName;
	}

	public void setActivitySubmitName(String activitySubmitName) {
		this.activitySubmitName = activitySubmitName;
	}

	public String getCentreSubmitName() {
		return centreSubmitName;
	}

	public void setCentreSubmitName(String centreSubmitName) {
		this.centreSubmitName = centreSubmitName;
	}

	public String getSt_daySubmitName() {
		return st_daySubmitName;
	}

	public void setSt_daySubmitName(String st_daySubmitName) {
		this.st_daySubmitName = st_daySubmitName;
	}

	public String getEd_daySubmitName() {
		return ed_daySubmitName;
	}

	public void setEd_daySubmitName(String ed_daySubmitName) {
		this.ed_daySubmitName = ed_daySubmitName;
	}

	public String getSt_timeSubmitName() {
		return st_timeSubmitName;
	}

	public void setSt_timeSubmitName(String st_timeSubmitName) {
		this.st_timeSubmitName = st_timeSubmitName;
	}

	public String getEd_timeSubmitName() {
		return ed_timeSubmitName;
	}

	public void setEd_timeSubmitName(String ed_timeSubmitName) {
		this.ed_timeSubmitName = ed_timeSubmitName;
	}
	
	public String getActivityCodeName() {
		return activityCodeName;
	}

	public void setActivityCodeName(String activityCodeName) {
		this.activityCodeName = activityCodeName;
	}

	public void setActivityCodeValue(String activityCodeValue) {
		this.activityCodeValue = activityCodeValue;
	}

	public String getActivityCodeValue() {
		return activityCodeValue;
	}
	
	public String toString() {
		return "[" + activity + "|" + centre + "|" + st_day + "|" + ed_day
				+ "|" + st_time + "|" + ed_time + "|" + credit + "|"
				+ submitName + "|" + kaptchaValue + "]";
	}
	public String toFormModelString(){
		return "[name:"+name + ",credit:"+credit
			+ ",sn:" + submitName
			+ ",sv:" + submitValue
			+ ",kn:" + kaptchaName
			+ ",an:" + activitySubmitName
			+ ",cn:" + centreSubmitName
			+ ",sd:" + st_daySubmitName
			+ ",ed:" + ed_daySubmitName
			+ ",st:" + st_timeSubmitName
			+ ",et:" + ed_timeSubmitName
			+"]";
	}
}
